<template>
	<view>
		<view class="con" v-if="iskt">
			<view class="con__title">
				帮我选校
			</view>
			<view class="con__tip">
				本表信息为你严格保密，请如实填写
			</view>
			<view class="con__l" @click="callphone">
				联系我们
				<image src="/static/bwx/t21.png" class="con__l__icon" mode=""></image>
			</view>
			<u-swiper :list="list1" height="326.34rpx" radius='38rpx' bgColor="#D3D0D0"></u-swiper>
			<view class="con__bg">
				<image src="/static/bwx/Group_2121.png" class="con__bg__b1" mode=""></image>
				<!-- <image v-for="(item,index) in 6" :key="index" class="bx" :src="'/static/bwx/l'+index+'.png'" :class="'con__bg__bx'+index" mode=""></image> -->
			</view>
			<u-button :customStyle="{
				height:'101.15rpx',
				fontSize:'38rpx',
				width:'538.17rpx',
				color:'#00456A',
				marginTop:'40rpx',
				marginLeft:'82rpx'
			}" color="#93d8ff" shape='circle' @click="navto('/pages/xschool/xxx1')">帮我选校</u-button>
		</view>
		<view class="" style="background-color: #f3f4f6;display: flex;align-items: center;justify-content: center;"
			:style="{height:'calc(100vh - 95.42rpx)'}" v-else>
			<u-empty mode='history' text='当前选择区域暂未开通,可联系客服开放'>
				<!-- <u-button type="primary"></u-button> -->
			</u-empty>
		</view>
		<tabbar :current="1"></tabbar>
	</view>
</template>

<script>
	import home from '@/api/_home.js'
	export default {
		data() {
			return {
				list1:[],
				phone:'',
				iskt:false
			};
		},
		computed: {
			height() {
				const height = `calc(${uni.$u.addUnit(uni.$u.sys().statusBarHeight, 'px')})`
				return uni.$u.deepMerge(height)
			},
			bheight() {
				const height = uni.$u.addUnit(uni.$u.sys().safeAreaInsets.bottom, 'px');
				return uni.$u.deepMerge(height)
			},
		},
		methods:{
			async getbanner(){
				let res = await home.config({name:'siteDegree'})
				if(res.data.code==200){
					this.list1=res.data.data.siteDegree
				}
			},
			async getphone(){
				let res = await home.config({name:'Site_ContactPhone'})
				if(res.data.code==200){
					this.phone=res.data.data.Site_ContactPhone
				}
			},
			callphone(){
				// console.log(this.phone)
				uni.makePhoneCall({
					phoneNumber: this.phone //仅为示例
				});
			}
		},
		onLoad() {
			
		},
		onShow() {
			this.iskt=uni.getStorageSync('schoolkt')
			this.getbanner()
			this.getphone()
		}
	}
</script>

<style lang="scss">
	page {
		background: url('https://mp-b54a63ff-3ce2-4df8-8d6e-f855d8976d34.cdn.bspapp.com/img/Rectangle_106.png') 100% no-repeat;
		background-position: top;
		background-color: #eefffb;
		width: 750rpx;
	}
	.con{
		padding: 131rpx 24rpx 100rpx;
		&__title{
			font-family: Alimama ShuHeiTi, Alimama ShuHeiTi;
			font-weight: bold;
			font-size: 46rpx;
			color: #000000;
			line-height: 60rpx;
			padding-left: 40rpx;
		}
		&__tip{
			font-family: PingFang SC, PingFang SC;
			font-weight: 500;
			font-size: 27rpx;
			color: #878787;
			line-height: 40rpx;
			padding-left: 40rpx;
		}
		&__l{
			display: flex;
			align-items: center;
			margin-top: 34rpx;
			font-family: PingFang SC, PingFang SC;
			font-weight: 500;
			font-size: 31rpx;
			color: #000000;
			line-height: 40rpx;
			padding-left: 40rpx;
			margin-bottom: 20rpx;
			&__icon{
				width: 28.63rpx;
				height: 28.63rpx;
				margin-left: 10rpx;
			}
		}
		&__texta{
			margin-top: 20rpx;
			width: 640rpx;
			height: 286rpx;
			background: #D3D0D0;
			border-radius: 38rpx 38rpx 38rpx 38rpx;
			padding: 30rpx;
		}
		&__bg{
			width: 313rpx;
			height: 256rpx;
			position: relative;
			margin: 110rpx 0 0 194rpx;
			&__b1{
				width: 313rpx;
				height: 256rpx;
				position: absolute;
				top: 0;
				left: 0;
			}
			.bx{
				position: absolute;
			}
			&__bx0{
				width: 34.35rpx;
				height: 34.35rpx;
				bottom: -17rpx;
				right: 37rpx;
			}
			&__bx1{
				width: 20rpx;
				height: 20rpx;
				right: -10rpx;
				bottom: 19rpx;
			}
			&__bx2{
				width: 20rpx;
				height: 20rpx;
				right: 0;
				top: -40rpx;
			}
			&__bx3{
				width: 17rpx;
				height: 17rpx;
				top: -26rpx;
				left: 73rpx;
			}
			&__bx4{
				width: 24rpx;
				height: 24rpx;
				left: -20rpx;
				top: 27rpx;
			}
			&__bx5{
				width: 34.35rpx;
				height: 34.35rpx;
				bottom: 50rpx;
				left: -53rpx;
			}
		}
	}
</style>